package com.cqfae.deploycentral.app.web.vo;

import com.cqfae.deploycentral.app.dao.entity.FileSyncDetail;
import com.fasterxml.jackson.annotation.JsonFormat;

import java.io.Serializable;
import java.util.Date;

/**
 * Created by JIANGLU009 on 2017/11/6.
 */
public class FileSyncDetailVo implements Serializable {

    private Long id;

    private Long fileSyncId;

    private String syncTime;

    private String targetArea;

    private String targetIp;

    private String targetContent;

    private String statusCode;

    private String statusCodeStr;

    private String createBy;


    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date createTime;

    private String updateBy;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date updateTime;

    private String syncId;

    // 回调参数
    private String area;

    private String time;

    private String zone;

    private String status;

    public FileSyncDetailVo() {
        super();
    }

    public FileSyncDetailVo(FileSyncDetail model) {
        setId(model.getId());
        setFileSyncId(model.getFileSyncId());
        setSyncTime(model.getSyncTime());
        setTargetArea(model.getTargetArea());
        setTargetIp(model.getTargetIp());
        setTargetContent(model.getTargetContent());
        setStatusCode(model.getStatus());
        setCreateBy(model.getCreateBy());
        setCreateTime(model.getCreateTime());
        setUpdateBy(model.getUpdateBy());
        setUpdateTime(model.getUpdateTime());
    }

    public FileSyncDetail parseModel() {
        FileSyncDetail info = new FileSyncDetail();
        info.setId(getId());
        info.setSyncTime(getSyncTime());
        info.setFileSyncId(getFileSyncId());
        info.setTargetArea(getTargetArea());
        info.setTargetIp(getTargetIp());
        info.setTargetContent(getTargetContent());
        info.setStatus(getStatusCode());
        info.setCreateBy(getCreateBy());
        info.setCreateTime(getCreateTime());
        info.setUpdateBy(getUpdateBy());
        info.setUpdateTime(getUpdateTime());
        info.setStatus(getStatus());
        return info;
    }

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public Long getFileSyncId() {
        return fileSyncId;
    }

    public void setFileSyncId(Long fileSyncId) {
        this.fileSyncId = fileSyncId;
    }

    public String getSyncTime() {
        return syncTime;
    }

    public void setSyncTime(String syncTime) {
        this.syncTime = syncTime;
    }

    public String getTargetArea() {
        return targetArea;
    }

    public void setTargetArea(String targetArea) {
        this.targetArea = targetArea;
    }

    public String getTargetIp() {
        return targetIp;
    }

    public void setTargetIp(String targetIp) {
        this.targetIp = targetIp;
    }

    public String getTargetContent() {
        return targetContent;
    }

    public void setTargetContent(String targetContent) {
        this.targetContent = targetContent;
    }

    public String getStatusCode() {
        return statusCode;
    }

    public void setStatusCode(String statusCode) {
        this.statusCode = statusCode;
    }

    public String getStatusCodeStr() {
        return statusCodeStr;
    }

    public void setStatusCodeStr(String statusCodeStr) {
        this.statusCodeStr = statusCodeStr;
    }

    public String getCreateBy() {
        return createBy;
    }

    public void setCreateBy(String createBy) {
        this.createBy = createBy;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public String getUpdateBy() {
        return updateBy;
    }

    public void setUpdateBy(String updateBy) {
        this.updateBy = updateBy;
    }

    public Date getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

    public String getSyncId() {
        return syncId;
    }

    public void setSyncId(String syncId) {
        this.syncId = syncId;
    }

    public String getTime() {
        return time;
    }

    public void setTime(String time) {
        this.time = time;
    }

    public String getZone() {
        return zone;
    }

    public void setZone(String zone) {
        this.zone = zone;
    }

    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }

    public String getArea() {
        return area;
    }

    public void setArea(String area) {
        this.area = area;
    }
}
